package com.library.service.Impl;

import com.library.mapper.UserMapper;
import com.library.service.AdminService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
@Slf4j
public class AdminServiceImpl implements AdminService {

    @Autowired
    private UserMapper userMapper;

    @Override
    public void updateUserRole(Long userId, Integer role) {
        log.info("修改用户角色，userId:{},role:{}", userId, role);
        userMapper.updateUserRole(userId, role);
    }
}
